ul{text-align: center;}
li{display: inline-block;margin:5px;}
li a{display: block;padding:5px 10px; color: #fff;text-decoration: none;background: #777;}
li a.on{background: blue;}